var o, e = require, t = module, n = exports, i = this && this.__extends || (o = function(e, t) {
    return (o = Object.setPrototypeOf || {
        __proto__: []
    } instanceof Array && function(e, t) {
        e.__proto__ = t;
    } || function(e, t) {
        for (var o in t) t.hasOwnProperty(o) && (e[o] = t[o]);
    })(e, t);
}, function(e, t) {
    function n() {
        this.constructor = e;
    }
    o(e, t), e.prototype = null === t ? Object.create(t) : (n.prototype = t.prototype, 
    new n());
}), a = this && this.__decorate || function(e, t, o, n) {
    var r, a = arguments.length, i = a < 3 ? t : null === n ? n = Object.getOwnPropertyDescriptor(t, o) : n;
    if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) i = Reflect.decorate(e, t, o, n); else for (var c = e.length - 1; 0 <= c; c--) (r = e[c]) && (i = (a < 3 ? r(i) : 3 < a ? r(t, o, i) : r(t, o)) || i);
    return 3 < a && i && Object.defineProperty(t, o, i), i;
};

Object.defineProperty(n, "__esModule", {
    value: !0
});

var r = e("BaseView"), s = e("Global"), c = e("AccelerometerTigger"), l = e("GameConfig"), d = e("GameData"), u = e("UIManager"), p = e("WebManager"), h = cc._decorator, f = h.ccclass, g = h.property, m = function(t) {
    function e() {
        var e = null !== t && t.apply(this, arguments) || this;
        return e.viewname = "", e.root = null, e.tigger = null, e;
    }
    return i(e, t), e.prototype.onClickVideo = function() {
        var t = this;
        if (GA.Info.underCheck && l.GC.isDebug) return cc.systemEvent.emit("videoEnd", "elf"), 
        void this.callback();
        this.pushEvent("视频试用"), GA.rewardOperation({
            tag: "elf",
            page: "",
            byVideo: !0,
            result: function(e) {
                e.reward && (cc.systemEvent.emit("videoEnd", "elf"), cc.isValid(t) && t.callback());
            }
        });
    }, e.prototype.callback = function() {
        s.G.tryPetIdx = 200, d.GD.lastPetDataIdx = d.GD.petDataIdx, d.GD.petDataIdx = 2, 
        u.default.getInstance().hideAllPnl(), u.default.getInstance().showPnl("start");
    }, e.prototype.pushEvent = function(e) {
        p.default.getInstance().sentLog("点击" + this.viewname + "界面" + e + "按键");
    }, e.prototype.showPnl = function() {
        this.root.active = !0;
    }, e.prototype.hidePnl = function() {
        this.root.active = !1;
    }, a([ g ], e.prototype, "viewname", void 0), a([ g(cc.Node) ], e.prototype, "root", void 0), 
    a([ g(c.default) ], e.prototype, "tigger", void 0), a([ f ], e);
}(r.default);

n.default = m;